﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using famails.bus;
using famails.common;
using famails.dto;

namespace famails.BackEnd.page
{
    public partial class AccountActive : System.Web.UI.Page
    {
        protected void Page_Load(object sender, EventArgs e)
        {
            if (!IsPostBack)
            {
                int id = 0;
                int.TryParse(Request.QueryString["id"], out id);
                if (id > 0)
                {
                    ClientBUS bus = new ClientBUS();
                    if (bus.Customer_Active(id))
                    {
                        Common.SendMailActiveSuccess(id);
                        Response.Redirect("login.aspx", false);
                    }
                }
            }
        }
    }
}